Drop bundled copy of linux/if_arp.h
authorZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>
Wed, 15 Sep 2021 14:33:05 +0000 (16:33 +0200)
committerAdrian Bunk <bunk@debian.org>
Sun, 25 Aug 2024 19:05:15 +0000 (22:05 +0300)
commit2139b2e5271114352b98434f36db80e659e48d0b
tree7d47a0060f6ecfd93e4aa95b0d170d63e6d8ef78
parent4ea9f4c9b8afe34bf774c816eb830e93d85b1d17
Drop bundled copy of linux/if_arp.h

As far as I can see, we use this to get a list of ARPHRD_* defines (used in
particular for Type= in .link files). If we drop our copy, and build against
old kernel headers, the user will have a shorter list of types available.  This
seems OK, and I don't think it's worth carrying our own version of this file
just to have newest possible entries.

7c5b9952c4f6e2b72f90edbe439982528b7cf223 recently updated this file, but we'd
have to update it every time the kernel adds new entries. But if we look at
the failure carefully:

src/basic/arphrd-from-name.gperf:65:16: error: ‘ARPHRD_MCTP’ undeclared (first use in this function); did you mean ‘ARPHRD_FCPP’?
   65 | MCTP, ARPHRD_MCTP
      |                ^~
      |                ARPHRD_FCPP

we see that the list we were generating was from the system headers, so it was
only as good as the system headers anyway, without the newer entries in our
bundled copy, if there were any. So let's make things simpler by always using
system headers.

And if somebody wants to fix things so that we always have the newest list,
then we should just generate and store the converted list, not the full header.

(cherry picked from commit e7f46ee3ae1cc66a94b293957721d68dc09d7449)

Gbp-Pq: Name Drop-bundled-copy-of-linux-if_arp.h.patch
src/basic/linux/if_arp.h [deleted file]
src/basic/meson.build